﻿/**
 * 
 * @file MaterialDensityWidget.h
 * @brief 材料密度界面声明
 * @author BaGuijun (baguijun@163.com)
 * @date 2024-04-22
 * 
 */
#ifndef MaterialDensityWidget_H
#define MaterialDensityWidget_H

#include "MaterialWidgetBase.h"

namespace Ui
{
    class MaterialDensityWidget;
}

namespace Interface
{
    class FITKAbaMaterialDensity;
}
namespace GUI
{
    /**
     * @brief 材料密度界面声明
     * @author BaGuijun (baguijun@163.com)
     * @date 2024-04-22
     */
    class MaterialDensityWidget : public MaterialWidgetBase
    {
        Q_OBJECT;
    public:
        /**
         * @brief Construct a new Mat Item Density Form object
         * @param[i]  item           密度材料对象
         * @param[i]  parent         父对象
         * @author BaGuijun (baguijun@163.com)
         * @date 2024-04-22
         */
        explicit MaterialDensityWidget(EventOper::ParaWidgetInterfaceOperator * oper,Interface::FITKAbaMaterialDensity* item, QWidget* parent = nullptr );
        /**
         * @brief Destroy the Mat Item Density Form object
         * @author BaGuijun (baguijun@163.com)
         * @date 2024-04-22
         */
        ~MaterialDensityWidget( );
        /**
         * @brief 数据检查
         * @return true 成功
         * @return false 失败
         * @author BaGuijun (baguijun@163.com)
         * @date 2024-06-12
         */
        bool checkValue() override;
        /**
         * @brief 存储数据
         * @return true 成功
         * @return false 失败
         * @author BaGuijun (baguijun@163.com)
         * @date 2024-06-12
         */
        bool saveValue() override;
    private:
        /**
         * @brief 初始化UI
         * @author BaGuijun (baguijun@163.com)
         * @date 2024-06-20
         */
        void initUi();
    private slots:
        ;
        /**
         * @brief 材料温度控件点击事件
         * @param[i]  checked        点击状态
         * @author BaGuijun (baguijun@163.com)
         * @date 2024-06-20
         */
        void on_checkBox_temp_clicked(bool checked);
    private:
        /**
         * @brief ui对象
         * @author BaGuijun (baguijun@163.com)
         * @date 2024-04-22
         */
        Ui::MaterialDensityWidget*   _ui = nullptr;
        /**
         * @brief 材料密度对象
         * @author BaGuijun (baguijun@163.com)
         * @date 2024-04-22
         */
        Interface::FITKAbaMaterialDensity* _densityItem = nullptr;
    };
}  // namespace GUI

#endif  // MaterialDensityWidget_H
